<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
    xmlns:h="http://xmlns.jcp.org/jsf/html"
    xmlns:f="http://xmlns.jcp.org/jsf/core"
    xmlns:c="http://xmlns.jcp.org/jsp/jstl/core">

    <ui:composition template="/WEB-INF/content/layout.xhtml">
        <ui:define name="title">${msg['menu.server.locale']}</ui:define>
        <ui:define name="content">

<input id="locale-input" data-type="search" placeholder="${msg['filter']}" />
<table border="1" style="white-space: nowrap;" data-role="table" data-mode="columntoggle" data-filter="true" data-input="#locale-input">
<thead>
<tr>
<th>${msg['locale']}</th>
<th data-priority="1">${msg['language']}</th>
<th data-priority="1">${msg['country']}</th>
<th data-priority="1">${msg['server.locale.number']}</th>
<th data-priority="1">${msg['server.locale.percent']}</th>
<th>${msg['currency']}</th>
<th>${msg['server.locale.date.short']}</th>
<th data-priority="1">${msg['server.locale.date.medium']}</th>
<th data-priority="1">${msg['server.locale.date.long']}</th>
<th data-priority="1">${msg['server.locale.date.full']}</th>
<th data-priority="1">${msg['server.locale.time.short']}</th>
<th data-priority="1">${msg['server.locale.time.medium']}</th>
<th data-priority="1">${msg['server.locale.time.long']}</th>
<th data-priority="1">${msg['server.locale.time.full']}</th>
</tr>
</thead>
<tbody>
<c:forEach items="${bean.locales}" var="l">
<tr>
<td>${l}</td>
<td>${l.displayLanguage}</td>
<td>${l.displayCountry}</td>
<td><h:outputText value="#{bean.number}" ><f:convertNumber locale="#{l}" /></h:outputText></td>
<td><h:outputText value="#{bean.number / 100}" ><f:convertNumber locale="#{l}" type="percent" minFractionDigits="2" /></h:outputText></td>
<td><h:outputText value="#{bean.number}" ><f:convertNumber locale="#{l}" type="currency" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" dateStyle="short" type="date" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" dateStyle="medium" type="date" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" dateStyle="long" type="date" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" dateStyle="full" type="date" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" timeStyle="short" type="time" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" timeStyle="medium" type="time" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" timeStyle="long" type="time" /></h:outputText></td>
<td><h:outputText value="#{bean.now}" ><f:convertDateTime locale="#{l}" timeZone="${sessionScope.TIMEZONE}" timeStyle="full" type="time" /></h:outputText></td>
</tr>
</c:forEach>
</tbody>
</table>

        </ui:define>
    </ui:composition>

</html>
